snippet php
	<?php
	${1}
	?>
snippet inc
	include '${1:file}';${2}
snippet inc1
	include_once '${1:file}';${2}
snippet req
	require '${1:file}';${2}
snippet req1
	require_once '${1:file}';${2}
# $GLOBALS['...']
snippet globals
	$GLOBALS['${1:variable}']${2: = }${3:something}${4:;}${5}
snippet $_ COOKIE['...']
	$_COOKIE['${1:variable}']${2}
snippet $_ ENV['...']
	$_ENV['${1:variable}']${2}
snippet $_ FILES['...']
	$_FILES['${1:variable}']${2}
snippet $_ Get['...']
	$_GET['${1:variable}']${2}
snippet $_ POST['...']
	$_POST['${1:variable}']${2}
snippet $_ REQUEST['...']
	$_REQUEST['${1:variable}']${2}
snippet $_ SERVER['...']
	$_SERVER['${1:variable}']${2}
snippet $_ SESSION['...']
	$_SESSION['${1:variable}']${2}
# Start Docblock
snippet /*
	/**
	 * ${1:name}
	 *
	 * @${2:params}
	 **/
# Class - post doc
snippet doc_cp
	/**
	 * ${1:undocumented class}
	 *
	 * @package ${2:default}
	 * @author ${3:`g:snips_author`}
	**/${4}
# Class Variable - post doc
snippet doc_vp
	/**
	 * ${1:undocumented class variable}
	 *
	 * @var ${2:string}
	 **/${3}
# Class Variable
snippet doc_v
	/**
	 * ${3:undocumented class variable}
	 *
	 * @var ${4:string}
	 **/
	${1:var} $${2};${5}
# Class
snippet doc_c
	/**
	 * ${3:undocumented class}
	 *
	 * @packaged ${4:default}
	 * @author ${5:`g:snips_author`}
	 **/
	${1:}class ${2:}
	{${6}
	} // END $1class $2
# Constant Definition - post doc
snippet doc_dp
	/**
	 * ${1:undocumented constant}
	 **/${2}
# Constant Definition
snippet doc_d
	/**
	 * ${3:undocumented constant}
	 **/
	define(${1}, ${2});${4}
# Function - post doc
snippet doc_fp
	/**
	 * ${1:undocumented function}
	 *
	 * @return ${2:void}
	 * @author ${3:`g:snips_author`}
	 **/${4}
# Function signature
snippet doc_s
	/**
	 * ${4:undocumented function}
	 *
	 * @return ${5:void}
	 * @author ${6:`g:snips_author`}
	 **/
	${1}function ${2}(${3});${7}
# Function
snippet doc_f
	/**
	 * ${4:undocumented function}
	 *
	 * @return ${5:void}
	 * @author ${6:`g:snips_author`}
	 **/
	${1}function ${2}(${3})
	{${7}
	}
# Header
snippet doc_h
	/**
	 * ${1}
	 *
	 * @author ${2:`g:snips_author`}
	 * @version ${3:$Id$}
	 * @copyright ${4:$2}, `strftime('%d %B, %Y')`
	 * @package ${5:default}
	 **/
	
	/**
	 * Define DocBlock
	 *//
# Interface
snippet doc_i
	/**
	 * ${2:undocumented class}
	 *
	 * @package ${3:default}
	 * @author ${4:`g:snips_author`}
	 **/
	interface ${1:}
	{${5}
	} // END interface $1
# class ...
snippet class
	/**
	 * ${1}
	 **/
	class ${2:ClassName}
	{
		${3}
		function ${4:__construct}(${5:argument})
		{
			${6:// code...}
		}
	}
# define(...)
snippet def
	define('${1}'${2});${3}
# defined(...)
snippet def?
	${1}defined('${2}')${3}
snippet wh
	while (${1:/* condition */}) {
		${2:// code...}
	}
# do ... while
snippet do
	do {
		${2:// code... }
	} while (${1:/* condition */});
snippet if
	if (${1:/* condition */}) {
		${2:// code...}
	}
snippet ife
	if (${1:/* condition */}) {
		${2:// code...}
	} else {
		${3:// code...}
	}
	${4}
snippet else
	else {
		${1:// code...}
	}
snippet elseif
	elseif (${1:/* condition */}) {
		${2:// code...}
	}
# Tertiary conditional
snippet t
	$${1:retVal} = (${2:condition}) ? ${3:a} : ${4:b};${5}
snippet switch
	switch ($${1:variable}) {
		case '${2:value}':
			${3:// code...}
			break;
		${5}
		default:
			${4:// code...}
			break;
	}
snippet case
	case '${1:value}':
		${2:// code...}
		break;${3}
snippet for
	for ($${2:i} = 0; $$2 < ${1:count}; $$2${3:++}) {
		${4: // code...}
	}
snippet fe
	foreach ($${1:data} as $k => $v) {
		${2:// code...}
	}
snippet fun
	${1:public }function ${2:FunctionName}(${3})
	{
		${4:// code...}
	}
# $... = array (...)
snippet array
	$${1:arrayName} = array('${2}' => ${3});${4}
# Function
snippet func
	function ${1:function_name}(${2:arguments}) {
		${3:// body...}
	}
# the following add by alex
snippet eq
	== ${1}
snippet neq
	!= ${1}
snippet -
	 => ${1} ,
snippet el
	else {
		${1}
	}
snippet ei
	elseif(${1}) {
		
	}
snippet fo
	foreach($${1} as $k=>$v){

	}
snippet fi
	for($i=0 ;$i < ${1} ;$i++){

	}
snippet e
	echo ${1:test} ;${2}
snippet et
	echo $${1}.'<br />' ;
snippet es
	echo "<script>alert('".${1}."')</script>"${2} ;
snippet est
	echo "<script>alert('ok')</script>";exit() ;
snippet eb
	echo '<br />' ;${1}
snippet ex
	exit() ;
snippet em
	empty(${1})
snippet re
	return ${1} ;
snippet pr
	print_r(${1}) ;
snippet fu
	function ${1}(){
		${2}
	}
snippet p
	$_POST['${1}']
snippet g
	$_GET['${1}']
snippet f
	$_FILES['${1}']
snippet a
	array(${1})
snippet ia
	in_array(${1})
snippet im
	implode(',', ${1})
snippet ee
	explode('${1}', )
snippet xml
	header("Content-Type:text/xml"); 
	echo "<?xml version='1.0' encoding='gb2312'?>\n";
	echo "<colinivy>$name</colinivy>" ;
snippet gda
	gmdate('Y-m-d H:i',${1}) ;
snippet da
	date('Y-m-d H:i',${1}) ;
snippet civy
	debugger("result: ${1}") ;
snippet de
	$console = ${1}; 

	require_once('../FirePHPCore/FirePHP.class.php');
	$firephp = FirePHP::getInstance(true);
	$firephp->log($console, 'result');
snippet je
	json_encode(${1})
snippet lt
	< ${1}
snippet nlt
	> ${1}
snippet ss
	$_SESSION['${1}']
snippet sr
	$_SERVER['PHP_SELF']
snippet er
	error_reporting(0);
snippet fpc
	file_put_contents($filename, ${1});
snippet fgc
	file_get_contents(${1});
snippet ur
	$query = "update pm_user set mall_cate = '{$mall_cate}' where name like '{$_SESSION['userName']}' " ;
	update_row($query) ;
snippet ir
	$query = "insert into pm_user set name ='{$name}', pwd='', group_id=0, role_id='1',id_type=1" ;
	insert_row($query) ;
snippet gr
	$query = "select id from user where id = {$id}" ;
	$${1} = get_row($query) ;
snippet iset
	$result_q = mysql_query($query) ;
	if(mysql_num_rows($result_q) == 0){
		echo 'no data' ;
	}
